Home

Operator Usage

Name

recursive-dump

Description

recursive-dump(|op: op1> + |op: op2> ... + |op: opn>) input-sp
print out the given operators applied to the kets in the input superposition
and then print out known knowledge for all the "daughter" kets
for now, we only do one layer of recursion, we may change this in the future


Examples

-- load some sample knowledge:
age |Fred> => |37>
friends |Fred> => |Rob> + |Mary> + |Matt> + |Sam>

age |Sam> => |41>
friends |Sam> => |Fred> + |Liz> + |Emma>

-- now recursive-dump the friends of Fred:
recursive-dump(|op: friends>) |Fred>
    friends|Fred> => |Rob> + |Mary> + |Matt> + |Sam>
        age|Fred> => |37>
        age|Sam> => |41>
        friends|Sam> => |Fred> + |Liz> + |Emma>


See also

Operator type

context function 1